package cn.player.entity;

import android.os.Parcel;
import android.os.Parcelable;

/**
 * Created by min on 2016/6/17.
 */
public class VideoBean implements Parcelable {
    private int id;
    private String name;
    private String description;
    private String cover;
    private int duration;
    private int users_count;
    private int watchers_count;
    private String qiniu_mp4_video_url;
    private String qiniu_m3u8_video_url;

    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getCover() {
        return cover;
    }

    public void setCover(String cover) {
        this.cover = cover;
    }

    public int getDuration() {
        return duration;
    }

    public void setDuration(int duration) {
        this.duration = duration;
    }

    public int getUsers_count() {
        return users_count;
    }

    public void setUsers_count(int users_count) {
        this.users_count = users_count;
    }

    public int getWatchers_count() {
        return watchers_count;
    }

    public void setWatchers_count(int watchers_count) {
        this.watchers_count = watchers_count;
    }

    public String getQiniu_mp4_video_url() {
        return qiniu_mp4_video_url;
    }

    public void setQiniu_mp4_video_url(String qiniu_mp4_video_url) {
        this.qiniu_mp4_video_url = qiniu_mp4_video_url;
    }

    public String getQiniu_m3u8_video_url() {
        return qiniu_m3u8_video_url;
    }

    public void setQiniu_m3u8_video_url(String qiniu_m3u8_video_url) {
        this.qiniu_m3u8_video_url = qiniu_m3u8_video_url;
    }

    @Override
    public int describeContents() {
        return 0;
    }

    @Override
    public void writeToParcel(Parcel dest, int flags) {
        dest.writeInt(this.id);
        dest.writeString(this.name);
        dest.writeString(this.description);
        dest.writeString(this.cover);
        dest.writeInt(this.duration);
        dest.writeInt(this.users_count);
        dest.writeInt(this.watchers_count);
        dest.writeString(this.qiniu_mp4_video_url);
        dest.writeString(this.qiniu_m3u8_video_url);
    }

    public VideoBean() {
    }

    protected VideoBean(Parcel in) {
        this.id = in.readInt();
        this.name = in.readString();
        this.description = in.readString();
        this.cover = in.readString();
        this.duration = in.readInt();
        this.users_count = in.readInt();
        this.watchers_count = in.readInt();
        this.qiniu_mp4_video_url = in.readString();
        this.qiniu_m3u8_video_url = in.readString();
    }

    public static final Creator<VideoBean> CREATOR = new Creator<VideoBean>() {
        @Override
        public VideoBean createFromParcel(Parcel source) {
            return new VideoBean(source);
        }

        @Override
        public VideoBean[] newArray(int size) {
            return new VideoBean[size];
        }
    };
}
